//
//  HELHomeCell.m
//  sanda
//
//  Created by wsj2015 on 16/7/11.
//  Copyright © 2016年 陈武琦. All rights reserved.
//

#import "HELHomeCell.h"
#import "UIImageView+UIActivityIndicatorForSDWebImage.h"
#import "UIImageView+WebCache.h"
@implementation HELHomeCell

- (void)awakeFromNib {
    // Initialization code
    //适配屏幕
   
   
    if (kScreenWidth ==320) {
        if (kScreenHeight ==480) {
            self.iconHeight.constant =66;
        }else{
            self.iconHeight.constant =66;
            
        }
        
    }else if(kScreenWidth == 375){
         self.iconHeight.constant =70;
    }else if (kScreenWidth > 400){
        self.iconHeight.constant =80;
    }
    

    
    
    
}
- (void)setModel:(HELStudyDataModel *)model{
//    [self.iconImageView setImageWithURL:[NSURL URLWithString:model.smallpicUrl ] usingActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];
    self.iconImageView.layer.borderColor = kBorderColor.CGColor;
    self.iconImageView.layer.borderWidth = 1;
    [self.iconImageView sd_setImageWithURL:[NSURL URLWithString:model.attachUrlMap.mid] placeholderImage:[UIImage imageNamed:@"暂无图片.jpg"]];
    
    self.title.text = model.name;
//    if (model.viewNum) {
//      self.scanLabel.text  = [NSString stringWithFormat:@"%@",model.viewNum];
//    }else{
//     self.scanLabel.text  =@"0";
//    }
   
//    self.commentCountLabel.text = [NSString stringWithFormat:@"%@",model.commentNum];
  
}
@end
